/*
 * Created by JFormDesigner on Fri Oct 28 13:39:30 CST 2022
 */

package com.liyu.ui;

import javax.swing.*;
import javax.swing.table.DefaultTableModel;
import java.awt.*;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;

/**
 * @author yht
 */
public class CheckFrame extends JFrame {
    // JFormDesigner - Variables declaration - DO NOT MODIFY  //GEN-BEGIN:variables  @formatter:off
    private JTabbedPane tabbedPane1;
    private JPanel userCheck;
    private JPanel goodsCheck;
    private JPanel buttonPanel;
    private JButton checkButton;
    private JButton updataButton;
    private JScrollPane goodInfoScrollPane;
    private JTable goodInfoTable;
    private JMenuBar menuBar;
    private JMenu selfMenu;
    private JMenuItem selfInfoMenuItem;
    private JMenuItem goodsInfoMenuItem;
    private JMenuItem viewMenuItem;
    private JMenu helpMenu;
    private JMenuItem updataMenuItem;
    private JMenuItem helpMenuItem;
    private JMenu masterMenu;
    private JMenuItem adimMenuItem;
    private JMenuItem userMenuItem;

    public CheckFrame() {
        initComponents();
    }

    private void table1MouseClicked(MouseEvent e) {
        // TODO add your code here
    }

    private void initComponents() {
        // JFormDesigner - Component initialization - DO NOT MODIFY  //GEN-BEGIN:initComponents  @formatter:off
        tabbedPane1 = new JTabbedPane();
        userCheck = new JPanel();
        goodsCheck = new JPanel();
        buttonPanel = new JPanel();
        checkButton = new JButton();
        updataButton = new JButton();
        goodInfoScrollPane = new JScrollPane();
        goodInfoTable = new JTable();
        menuBar = new JMenuBar();
        selfMenu = new JMenu();
        selfInfoMenuItem = new JMenuItem();
        goodsInfoMenuItem = new JMenuItem();
        viewMenuItem = new JMenuItem();
        helpMenu = new JMenu();
        updataMenuItem = new JMenuItem();
        helpMenuItem = new JMenuItem();
        masterMenu = new JMenu();
        adimMenuItem = new JMenuItem();
        userMenuItem = new JMenuItem();

        //======== this ========
        Container contentPane = getContentPane();
        contentPane.setLayout(null);

        //======== tabbedPane1 ========
        {
            tabbedPane1.setTabPlacement(SwingConstants.LEFT);
            tabbedPane1.setBackground(Color.white);
            tabbedPane1.setAutoscrolls(true);

            //======== userCheck ========
            {
                userCheck.setLayout(new BorderLayout());
            }
            tabbedPane1.addTab("\u7528\u6237\u7ba1\u7406", userCheck);

            //======== goodsCheck ========
            {
                goodsCheck.setLayout(new BorderLayout());

                //======== buttonPanel ========
                {
                    buttonPanel.setLayout(new FlowLayout(FlowLayout.CENTER, 100, 5));

                    //---- checkButton ----
                    checkButton.setText("\u5ba1\u6838");
                    buttonPanel.add(checkButton);

                    //---- updataButton ----
                    updataButton.setText("\u5237\u65b0\u5217\u8868");
                    updataButton.setAlignmentX(0.5F);
                    buttonPanel.add(updataButton);
                }
                goodsCheck.add(buttonPanel, BorderLayout.SOUTH);

                //======== goodInfoScrollPane ========
                {

                    //---- goodInfoTable ----
                    goodInfoTable.setModel(new DefaultTableModel(
                            new Object[][]{
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                                    {null, null, null, null, null},
                            },
                            new String[]{
                                    "\u5546\u54c1ID", "\u5546\u54c1\u540d", "\u5546\u54c1\u6570\u91cf", "\u5546\u54c1\u4ef7\u683c", "\u7528\u6237\u64cd\u4f5c"
                            }
                    ) {
                        Class<?>[] columnTypes = new Class<?>[]{
                                String.class, Object.class, Integer.class, Double.class, Object.class
                        };

                        @Override
                        public Class<?> getColumnClass(int columnIndex) {
                            return columnTypes[columnIndex];
                        }
                    });
                    goodInfoTable.setPreferredSize(null);
                    goodInfoTable.setPreferredScrollableViewportSize(new Dimension(450, 300));
                    goodInfoTable.addMouseListener(new MouseAdapter() {
                        @Override
                        public void mouseClicked(MouseEvent e) {
                            table1MouseClicked(e);
                        }
                    });
                    goodInfoScrollPane.setViewportView(goodInfoTable);
                }
                goodsCheck.add(goodInfoScrollPane, BorderLayout.EAST);
            }
            tabbedPane1.addTab("\u5546\u54c1\u5ba1\u6838", goodsCheck);
        }
        contentPane.add(tabbedPane1);
        tabbedPane1.setBounds(0, 22, tabbedPane1.getPreferredSize().width, 372);

        //======== menuBar ========
        {

            //======== selfMenu ========
            {
                selfMenu.setText("\u6211\u7684");

                //---- selfInfoMenuItem ----
                selfInfoMenuItem.setText("\u4e2a\u4eba\u4fe1\u606f\u7ba1\u7406>");
                selfMenu.add(selfInfoMenuItem);

                //---- goodsInfoMenuItem ----
                goodsInfoMenuItem.setText("\u4e2a\u4eba\u5546\u54c1\u7ba1\u7406>");
                selfMenu.add(goodsInfoMenuItem);

                //---- viewMenuItem ----
                viewMenuItem.setText("\u5546\u54c1\u6d4f\u89c8>");
                viewMenuItem.setEnabled(false);
                selfMenu.add(viewMenuItem);
            }
            menuBar.add(selfMenu);

            //======== helpMenu ========
            {
                helpMenu.setText("\u5e2e\u52a9");

                //---- updataMenuItem ----
                updataMenuItem.setText("\u83b7\u53d6\u66f4\u65b0");
                helpMenu.add(updataMenuItem);

                //---- helpMenuItem ----
                helpMenuItem.setText("\u4f7f\u7528\u8bf4\u660e");
                helpMenu.add(helpMenuItem);
            }
            menuBar.add(helpMenu);

            //======== masterMenu ========
            {
                masterMenu.setText("\u7ba1\u7406");

                //---- adimMenuItem ----
                adimMenuItem.setText("\u524d\u5f80\u7ba1\u7406\u5458\u754c\u9762>");
                masterMenu.add(adimMenuItem);

                //---- userMenuItem ----
                userMenuItem.setText("\u524d\u5f80\u7528\u6237\u754c\u9762>");
                masterMenu.add(userMenuItem);
            }
            menuBar.add(masterMenu);
        }
        contentPane.add(menuBar);
        menuBar.setBounds(0, 0, 528, menuBar.getPreferredSize().height);

        {
            // compute preferred size
            Dimension preferredSize = new Dimension();
            for (int i = 0; i < contentPane.getComponentCount(); i++) {
                Rectangle bounds = contentPane.getComponent(i).getBounds();
                preferredSize.width = Math.max(bounds.x + bounds.width, preferredSize.width);
                preferredSize.height = Math.max(bounds.y + bounds.height, preferredSize.height);
            }
            Insets insets = contentPane.getInsets();
            preferredSize.width += insets.right;
            preferredSize.height += insets.bottom;
            contentPane.setMinimumSize(preferredSize);
            contentPane.setPreferredSize(preferredSize);
        }
        pack();
        setLocationRelativeTo(getOwner());
        // JFormDesigner - End of component initialization  //GEN-END:initComponents  @formatter:on
    }
    // JFormDesigner - End of variables declaration  //GEN-END:variables  @formatter:on
}
